#ifndef IncrementalForceIteration_H
#define IncrementalForceIteration_H


#include "IterationState.h"
#include "PArray.h"

class LinearCGState;
class DeformationState;

class IncrementalForceIteration : public IterationState
{
public:
	Array<Real> todo_delta_force_;
	Array<Real> current_delta_force_;
	Array<Real> current_delta_displ_;
	Real current_df_len_;
	int Dimension ()const;
	LinearCGState * cg_state_;
	DeformationState * pstate_;

	IncrementalForceIteration (DeformationState*);

	bool GoodSolution (DeformationState const*) const;

	void UpdateIncrementalStep ();

	virtual void UpdateResidual (DeformationState const*);
	virtual LinkArray< Array<Real > > VectorVariables();

	virtual void Reinit (DeformationState const *);
	virtual void IterationStep (DeformationState *);
	~IncrementalForceIteration();
};

#endif /* IncrementalForceIteration_H */

